Skip to content

Conversation

@madamczyk-intel
Copy link
Contributor

No description provided.

Signed-off-by: Michal Adamczyk <[email protected]>
@adobrzyn adobrzyn added the documentation Improvements or additions to documentation label Oct 6, 2025
@adobrzyn adobrzyn merged commit 724f8c1 into vllm-project:main Nov 4, 2025
23 of 24 checks passed
The problem here lies in the denominator as it contains the sum of all terms. Fortunately we can split the calculation into two separate softmax and then readjust the results and combine them. Let's say we have:
$$z_1, z_2\text{ - local softmax results} \\ c_1, c_2 \text{ - local maxima} \\ s_1, s_2 \text{ - local sums}$$
We can then calculate:
$$c = max(c_1, c_2) \\ adj_i = e^{c_i-c} \\ s = s_1 * adj_1 + s_2 * adj_2\\ z_i\prime = \frac{z_i*s_i*adj_i}{s} $$
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Precommit fails here

PatrykWo added a commit that referenced this pull request Nov 4, 2025
Signed-off-by: PatrykWo <[email protected]>
@PatrykWo PatrykWo mentioned this pull request Nov 4, 2025
PatrykWo added a commit that referenced this pull request Nov 4, 2025
plus fix for PR #275

---------

Signed-off-by: PatrykWo <[email protected]>
PatrykWo pushed a commit that referenced this pull request Nov 5, 2025
Signed-off-by: Michal Adamczyk <[email protected]>
Co-authored-by: Agata Dobrzyniewicz <[email protected]>
PatrykWo added a commit that referenced this pull request Nov 5, 2025
plus fix for PR #275

---------

Signed-off-by: PatrykWo <[email protected]>
PatrykWo added a commit that referenced this pull request Nov 7, 2025
plus fix for PR #275

---------

Signed-off-by: PatrykWo <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation skip-gaudi-tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants